package se.statemachine.fsm.mvcstyle;

import junit.framework.TestCase;
import se.statemachine.fsm.interfacestyle.TurnstileFSM;
import se.statemachine.fsm.mvcstyle.impl.ModelImpl;

public class Test extends TestCase{

	public void testController() {
		
		Controller controller = new Controller();		
		ModelImpl model = new ModelImpl();
		MockupView view = new MockupView();
		
		controller.setView(view);
		view.setActionListener(controller);
		
		TurnstileFSM fsm = new TurnstileFSM();
											
		controller.setModel(model);
		controller.setTurnstileFsm(fsm);
		
		view.createAction(model.getCoinAction());		
		view.createAction(model.getPassAction());
		
		assertTrue(true);					
	}
}
